package org.chenmin.gwt.client.components;

import com.axellience.vuegwt.core.annotations.component.Component;
import com.axellience.vuegwt.core.annotations.component.Data;
import com.axellience.vuegwt.core.client.component.IsVueComponent;
import com.axellience.vuegwt.core.client.component.hooks.HasCreated;
import com.axellience.vueroutergwt.client.Route;
import com.axellience.vueroutergwt.client.VueRouteComponent;

@Component
public class BarComponent implements IsVueComponent ,VueRouteComponent,HasCreated {
    @Data
    Route route;

    @Data
    int id;

    @Override
    public void created() {
        route =  getRoute();
        id = Integer.parseInt(route.getParams().get("id")) ;
    }
}
